<?php

include(dirname(__FILE__).'/../../bootstrap/functional.php');

$browser = new sfTestFunctional(new sfBrowser());

$browser->

  info( '1 - Main page' )->
 
  get('/')->

  with('request')->begin()->
    isParameter('module', 'peachy')->
    isParameter('action', 'index')->
  end()->

  with('response')->begin()->
    isStatusCode(200)->
    checkElement('body', '/Welcome!/')->
  end()->
 
 
  info( '2 - 404 error' )->
 
  get('/thispageshouldneverexist')->

  with('request')->begin()->
    //isForwardedTo('peachy', 'error404')->
  end()->

  with('response')->begin()->
    isStatusCode(404)->
    checkElement('body', '/404/')->
  end()//->
 
  //info( '1 - Replag works as expected' )
;

